3D Graphics Programming with QuickDraw 3D 1.5.4
Previous | QD3D Book | Overview | Chapter Contents | Next |
When you pass a metahandler to QuickDraw 3D, it is called multiple times to build method tables and is then thrown away. You are guaranteed that your metahandler will never be called again after the call that was passed to it returns.
Your metahandler should contain a switch on the method type passed to it and should return the corresponding method as a TQ3XFunctionPointer :
typedef void (QD3D_CALLBACK *TQ3XFunctionPointer)(void);
typedef unsigned long TQ3XMethodType;
typedef TQ3XFunctionPointer (QD3D_CALLBACK *TQ3XMetaHandler)
(TQ3XMethodType methodType);
For a description of the QD3D_CALLBACK macro, see the QD3D.h header file.
A metahandler must always return a value. If it is passed a method type that it does not understand, it must return a value of NULL .
Previous | QD3D Book | Overview | Chapter Contents | Next |